package com.heima.article.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.heima.model.article.pojos.ApCollection;
import com.heima.model.common.dtos.ResponseResult;

public interface ApCollectionService extends IService<ApCollection> {
    /**
     * 收藏或取消收藏文章
     * @param userId 用户ID
     * @param articleId 文章ID
     * @param isCollect 是否收藏 true-收藏 false-取消收藏
     * @return
     */
    ResponseResult collectArticle(Integer userId, Long articleId, Boolean isCollect);

    ResponseResult isArticleCollected(Integer userId, Long articleId);

    ResponseResult getUserCollections(Integer userId, Integer page, Integer size);
}